
/**
 * 测试 m_text 模块文件 2
 * 2018-5-17
 * 原始创建者 : Zdream
 */

addModule({
	name: "Test Text 2",

	init: function(){
		addSceneFunc("tt1", this.scene0, this.name, null);
	},

	config: {
		duration: 1000000,
		_text: "你好, 说明层太慢了"
	},

	scene0 : function() {

        addRenderFunc("t1", function() {
            m_text.putCaption("zhangzhiyu");
            console.log("t1");
        }, {
            once : true,
            delay : 1000,
        });

        addRenderFunc("t2", function() {
            m_text.removeCaption();
            m_text.putTitle("laoqian");
            console.log("t2");
        }, {
            once : true,
            delay : 2000,
        });

        addRenderFunc("t3", function() {
            m_text.removeTitle();
            console.log("t3");
        }, {
            once : true,
            delay : 3000,
        });

        addRenderFunc("t4", function() {
            m_text.putCaption("Are you OK!");
            m_text.putTitle("Are you OK?");
            console.log("t4");
        }, {
            once : true,
            delay : 4000,
        });

        addRenderFunc("t5", function() {
            m_text.putCaption("Are you OK!!!!!");
            m_text.putTitle("Are you OK?????");
            console.log("t5");
        }, {
            once : true,
            delay : 5000,
        });

        addRenderFunc("t6", function() {
            m_text.removeCaption();
            m_text.removeTitle();
            console.log("t6");
        }, {
            once : true,
            delay : 6000,
        });

		addRenderFunc("end", function() {
			endScene();
		}, {
			once : true,
			delay : this.config.duration,
		});
	},
});
